Skip to content

[7.3] Fix tests bareword fallback with error suppression #3815

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed

[7.3] Fix tests bareword fallback with error suppression #3815

wants to merge 1 commit into from

Conversation

guilliamxavier
Copy link
Contributor

aad3987#r32133606 (only the unintentionally buggy tests)

Notes:

  • ext/standard/tests/serialize/serialization_miscTypes_001.phpt is considered a binary file, the change is just the same as for ext/standard/tests/general_functions/debug_zval_dump_v.phpt (on line 84 instead of 105)
  • after merging this into PHP-7.3, the merge of PHP-7.3 into PHP-7.4 will conflict on ext/standard/tests/array/*.phpt deleted files: the resolution is to simply discard them (i.e. re-delete them)

(cherry picked from commit aad3987)
(cherry picked from commit 76f8a90)
@nikic
Copy link
Member

nikic commented Feb 11, 2019

Merged as b3935ed, thanks :)

@nikic nikic closed this Feb 11, 2019
@guilliamxavier
Copy link
Contributor Author

@nikic Thanks for accepting =) but it looks like the subsequent merge (5ee1188) didn't change anything on the PHP-7.4 branch? I mean, the 13 ext/standard/tests/array/*.phpt files have been deleted, but the changes to the 5 other files (namely
ext/standard/tests/file/bug22414.phpt
ext/standard/tests/general_functions/debug_zval_dump_v.phpt
ext/standard/tests/serialize/serialization_miscTypes_001.phpt
ext/standard/tests/strings/explode.phpt
tests/lang/operators/bitwiseShiftLeft_variationStr.phpt
) should have been applied? Especially for the last one, compare:
https://github.com/php/php-src/blob/PHP-7.3/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt#L17
https://github.com/php/php-src/blob/PHP-7.4/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt#L17
https://github.com/php/php-src/blob/master/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt#L17
(Sorry for the noise if wrong)

@guilliamxavier
Copy link
Contributor Author

/ping @nikic Should I open a new PR for 7.4 with just those 5 files?

@nikic
Copy link
Member

nikic commented Feb 22, 2019

@guilliamxavier Yes please. I got confused here and thought the test changes were already in 7.4 rather than just master and did an -s ours merge.

@guilliamxavier
Copy link
Contributor Author

Here it is: #3876

guilliamxavier referenced this pull request Feb 23, 2019
Access to undefined constants will now always result in an Error
exception being thrown.

This required quite a few test changes, because there were many
buggy tests that unintentionally used bareword fallback in combination
with error suppression.
@guilliamxavier guilliamxavier deleted the fix-tests-bareword-fallback-error-suppression-7.3 branch February 25, 2019 17:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants